#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
#include <stdlib.h>

int main()
{
	int k = 0;
	int i = 0;
	scanf("%d", &k);
	long double x, y, r, x0, y0 = 0.0;
	for (i = 0; i < k; i++)
	{
		scanf("%Lf %Lf %Lf %Lf %Lf", &x, &y, &r, &x0, &y0);
		if ((x - x0) * (x - x0) + (y - y0) * (y - y0) > r * r)
			printf("No\n");
		else
			printf("Yes\n");
	}

	return 0;
}